package cn.com.shopec.erp.base.entity;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import org.hibernate.annotations.GenericGenerator;

@Entity
@Table(name = "TBL_PROFITS_PRODUCT_HIS")
public class ProfitsProductHistory {
	
	/**
	 * ID
	 */
	private String id;
	
	/**
	 * 货品编码
	 */
	private String productCode;
	
	/**
	 * code
	 */
	private String code;
	
	/**
	 * 让利比例
	 */
	private double profits;
	
	/**
	 * 删除标识 0:已删除 1：未删除
	 */
	private Integer deleteFlag;
	
	private String brandName;
	private String brandNo;
	private String casePakgSize;
	private String catName;
	private String catNo;
	private String commoName;
	private String commoNo;
	private Integer inventoryType;
	private double originalCost;
	private double originalRetailCost;
	private String prodBarCode;
	private double promotionsCost;
	private double promotionsRetailCost;
	private double salePrice;
	private Integer saleType;
	private String validTimeStart;
	private String validTimeEnd;
	private Long createTime;
	
	private ProfitsProduct profitsProduct;

	
	@GenericGenerator(name = "generator", strategy = "uuid.hex")
	@Id
	@GeneratedValue(generator = "generator")
	@Column(name = "id", unique = true, nullable = false, length = 32)
	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	@Column(name ="PRODUCT_CODE")
	public String getProductCode() {
		return productCode;
	}

	public void setProductCode(String productCode) {
		this.productCode = productCode;
	}
	@Column(name ="CODE")
	public String getCode() {
		return code;
	}

	public void setCode(String code) {
		this.code = code;
	}
	@Column(name ="PROFITS")
	public double getProfits() {
		return profits;
	}

	public void setProfits(double profits) {
		this.profits = profits;
	}
	@Column(name ="DELETE_FLAG")
	public Integer getDeleteFlag() {
		return deleteFlag;
	}

	public void setDeleteFlag(Integer deleteFlag) {
		this.deleteFlag = deleteFlag;
	}
	
	@Column(name ="BRAND_NAME")
	public String getBrandName() {
		return brandName;
	}

	public void setBrandName(String brandName) {
		this.brandName = brandName;
	}
	
	@Column(name ="BRAND_NO")
	public String getBrandNo() {
		return brandNo;
	}

	public void setBrandNo(String brandNo) {
		this.brandNo = brandNo;
	}
	
	@Column(name ="CASE_PAKG_SIZE")
	public String getCasePakgSize() {
		return casePakgSize;
	}

	public void setCasePakgSize(String casePakgSize) {
		this.casePakgSize = casePakgSize;
	}
	
	@Column(name ="CAT_NAME")
	public String getCatName() {
		return catName;
	}

	public void setCatName(String catName) {
		this.catName = catName;
	}
	
	@Column(name ="CAT_NO")
	public String getCatNo() {
		return catNo;
	}

	public void setCatNo(String catNo) {
		this.catNo = catNo;
	}
	
	@Column(name ="COMMO_NAME")
	public String getCommoName() {
		return commoName;
	}

	public void setCommoName(String commoName) {
		this.commoName = commoName;
	}
	
	@Column(name ="COMM_NO")
	public String getCommoNo() {
		return commoNo;
	}

	public void setCommoNo(String commoNo) {
		this.commoNo = commoNo;
	}
	
	@Column(name ="INVEN_TYPE")
	public Integer getInventoryType() {
		return inventoryType;
	}

	public void setInventoryType(Integer inventoryType) {
		this.inventoryType = inventoryType;
	}
	
	@Column(name ="ORIG_COST")
	public double getOriginalCost() {
		return originalCost;
	}

	public void setOriginalCost(double originalCost) {
		this.originalCost = originalCost;
	}
	
	@Column(name ="ORIG_RETAIL_COST")
	public double getOriginalRetailCost() {
		return originalRetailCost;
	}

	public void setOriginalRetailCost(double originalRetailCost) {
		this.originalRetailCost = originalRetailCost;
	}
	
	@Column(name ="PROD_BAR_CODE")
	public String getProdBarCode() {
		return prodBarCode;
	}

	public void setProdBarCode(String prodBarCode) {
		this.prodBarCode = prodBarCode;
	}
	
	@Column(name ="PROMOT_COST")
	public double getPromotionsCost() {
		return promotionsCost;
	}

	public void setPromotionsCost(double promotionsCost) {
		this.promotionsCost = promotionsCost;
	}
	
	@Column(name ="PROMOT_RETAIL_COST")
	public double getPromotionsRetailCost() {
		return promotionsRetailCost;
	}

	public void setPromotionsRetailCost(double promotionsRetailCost) {
		this.promotionsRetailCost = promotionsRetailCost;
	}
	
	@Column(name ="SALE_PRICE")
	public double getSalePrice() {
		return salePrice;
	}

	public void setSalePrice(double salePrice) {
		this.salePrice = salePrice;
	}
	
	@Column(name ="SALE_TYPE")
	public Integer getSaleType() {
		return saleType;
	}

	public void setSaleType(Integer saleType) {
		this.saleType = saleType;
	}
	
	@Column(name ="VALID_TIME_START")
	public String getValidTimeStart() {
		return validTimeStart;
	}

	public void setValidTimeStart(String validTimeStart) {
		this.validTimeStart = validTimeStart;
	}
	
	@Column(name ="VALID_TIME_END")
	public String getValidTimeEnd() {
		return validTimeEnd;
	}

	public void setValidTimeEnd(String validTimeEnd) {
		this.validTimeEnd = validTimeEnd;
	}
	
	@Column(name ="create_time")
	public Long getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Long createTime) {
		this.createTime = createTime;
	}

	@ManyToOne
	@JoinColumn(name = "pp_id")
	public ProfitsProduct getProfitsProduct() {
		return profitsProduct;
	}

	public void setProfitsProduct(ProfitsProduct profitsProduct) {
		this.profitsProduct = profitsProduct;
	}

}
